<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>更新</title>
</head>
<body>
<div th:replace="~{fragments/header::head}"></div>
<div th:replace="~{fragments/nav-bar::nav-bar}"></div>
<div>
    <br/>
</div>

<div class="container">
    <div>
        <div th:replace="~{fragments/user/left-bar::left-bar}"></div>

        <h4 class="page-title">文章更新</h4>
        <form action="/article/update" method="post">
            <div class="mb-3">
                <input type="hidden" name="commentAmount" th:value="${article.commentAmount}"/>
                <input type="hidden" name="id" th:value="${article.id}"/>
                <input type="hidden" name="publishTime" th:value="${article.publishTime}"/>

                <label>文章标题</label>
                <br>
                <input name="title" type="text" th:value="${article.title}">
                <br>
                <label for="exampleFormControlTextarea1" class="form-label">文章内容</label>
                <br>
                <textarea class="form-control" id="exampleFormControlTextarea1" rows="3" name="content"
                          th:text="${article.content}"></textarea>
            </div>
            <button type="submit" class="btn btn-primary">确定</button>
        </form>

        <div>
            <br/>
        </div>
    </div>
    <div th:replace="~{fragments/footer::foot}"></div>
</body>
</html>